package com.yazi.mxz.behavior.service.impl;

import javax.annotation.Resource;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.stereotype.Service;

import com.myframework.smhj.hibernate.Searching;
import com.myframework.smhj.hibernate.Page;
import com.yazi.mxz.behavior.dao.GoodsClassifyDao;
import com.yazi.mxz.behavior.entity.beans.GoodsClassify;
import com.yazi.mxz.behavior.service.GoodsClassifyService;


@Service("goodsClassifyService")
public class GoodsClassifyServiceImpl implements GoodsClassifyService {
	private static Logger log = LoggerFactory.getLogger(GoodsClassifyServiceImpl.class);
	
	@Resource
	GoodsClassifyDao goodsClassifyDao;
	
	@Override
	public GoodsClassify oneById(long classifyId) {
		log.debug("oneById：classifyId={}", classifyId);
		return goodsClassifyDao.get(classifyId);
	}
	
	@Override
	public Page<GoodsClassify> list(GoodsClassify classify, Searching si) {
		log.debug("list：");
		return goodsClassifyDao.listByExample(classify, si);
	}
	
	@Override
	public Page<GoodsClassify> listByGtUpdateTime(long updateTime, Searching si) {
		log.debug("listByGtUpdateTime：updateTime={},nowPage={}", updateTime, si.getNowPage());
		return goodsClassifyDao.listByGtUpdateTime(updateTime, si);
	}
	
}
